In video displays, a relationship exists between overall scene brightness and contrast. Typical displays have a contrast ratio around 100:1, or slightly higher. The human eye may adapt to a range of luminance of about 200,000:1, and at any particular adaptation level, the human eye is sensitive to a linear contrast over a luminance range of 300:1. Representing real images on a limited contrast medium such as film or video requires adjustments at authoring time to compose the overall scene brightness in a manner which appears to the eye as a dark scene or a light scene. This takes advantage of the eye's natural ability to adapt to its surroundings. Assuming that the video or film is a dominant part of the viewing area for the eye, the impression of a dark scene may be given with a video composition of mostly dark pixels. Similarly, the impression of a daylight scene may be given with a video composition of mostly white pixels.
When compared to actual daylight, or actual night, television is nowhere near as dark as the human eye can see in a dark room, nor can a television be anywhere near as bright as full daylight. In video, the absolute luminance of the original scene is rarely reproduced. In reality a relative luminance, which is proportional to the scene luminance, is reproduced. By using the adaptive capabilities in the human eye, film directors and video equipment attempt to provide a relative contrast. Viewers then adapt to white levels in their ambient environment, and respond to delta luma values as relative contrast in the ambient environment.
For example, in an extreme dark scene, with most pixels skewed toward the black end of the distribution of the luma spectrum, the eye is less sensitive to contrast. The overall power response curve of the eye increases, and boosting near white pixels increases spectral highlights and the appearance of sharpness.
As another example, in an extreme bright scene, with most pixels skewed toward the white end of the distribution, the eye is more sensitive to contrast. The overall power response curve of the eye decreases, and boosting near white does little or nothing. However, boosting contrast near black increases the relative contrast ratio, and the impression of sharpness.
If the source is composed well, the black level, white level and overall scene contrast are set well, and require little adjustment. This is also true of high-contrast content: daylight scenes, live action, and normal viewing environments. In other scenes such as film noir, low-contrast scenes, foggy or cloudy scenes, and old film movies, the contrast may not be well adjusted, or sometimes viewers may prefer higher contrast scenes. In such cases, it is necessary to increase contrast in a way that takes advantage of the eye's ability to adapt to scene brightness, but this may be done so as not to change the overall scene composition as desired by the original film director.
A histogram may be used to illustrate luma statistics, where the x-axis represents the brightness value of a pixel, which ranges from 0 (black) to 255 (white), and the y-axis represents the number of pixels. Examination of the histogram may give a general idea of the brightness of a frame. For example, in darker images, the histogram will be skewed to the left, where most of the pixels will be dark and closer to 0 (black), and vice versa for bright frames. Often, contrast stretch is applied to videos to achieve brightness more desirable by viewers.
Prior technology implemented a static contrast stretch independent of the histogram of an image, and where image information was available, usually only a single black stretch was performed based on the minimum level of the image. Prior algorithms did not have good mechanisms to prevent over-stretching, did not have mechanisms to adjust the contrast stretch for very narrow or skewed distribution images, or did not have mechanisms to perform a non-linear stretch to adapt to the power law response curve of the eye.
Further limitations and disadvantages of conventional and traditional approaches will become apparent to one of skill in the art, through comparison of such systems with some aspects of the present invention as set forth in the remainder of the present application with reference to the drawings.